<!DOCTYPE html>
<html>
    <?php echo $head; ?>
    <body>
        <!-- Home -->
        <div data-role="page" data-theme="a" class="type-interior">
            <div data-theme="b" data-role="header" data-id="head" data-position="fixed">
				<a data-role="button" data-direction="reverse" data-transition="flow" href="<?php echo site_url(); ?>" data-icon="home" data-iconpos="left" class="ui-btn-left">
                    Home
                </a>
				<h3>
                    Pencarian Rute
                </h3>
            </div>
            <div data-role="content" data-theme="a">	
				<?php echo form_open('pencarian/query',array('method' => 'get')); ?>
					<label for="keberangkatan" class="select">Stasiun Keberangkatan:</label>
	                <select name="keberangkatan" id="keberangkatan" data-native-menu="false">
						<option data-placeholder="true">Pilih Stasiun..<option>
						<?php foreach($table as $row): ?>
						<option value="<?php echo $row->id; ?>"><?php echo $row->Nama_Stasiun; ?></option>
						<?php endforeach; ?>
					</select>
	                <label for="tujuan" class="select">Stasiun Tujuan:</label>
	                <select name="tujuan" id="tujuan" data-native-menu="false">
						<option data-placeholder="true">Pilih Stasiun..<option>
						<?php foreach($table as $row): ?>
						<option value="<?php echo $row->id; ?>"><?php echo $row->Nama_Stasiun; ?></option>
						<?php endforeach; ?>
					</select>
	                <label for="waktuberangkat" class="input">Waktu Berangkat:</label>
                    <input type="text" name="waktuberangkat" id="waktuberangkat" value="<?php echo date('h:i A');?>"/>
                    <label for="waktukedatangan" class="input">Waktu Sampai:</label>
                    <input type="text" name="waktukedatangan" id="waktukedatangan" />
	                <input type="submit" value="Cari" data-icon="search"/>
                </form>
            </div>
			<?php echo $foot;?>
        </div>
        
        <script src="<?php echo base_url('js/mobiscroll-2.3.1.custom.min.js'); ?>" type="text/javascript"></script>
        <script>
			
			
			$(function(){
			    $('#waktuberangkat').mobiscroll().time({
			        theme: 'jqm',
			        display: 'modal',
			        mode: 'mixed'
			    });
			    
			    $('#waktukedatangan').mobiscroll().time({
			        theme: 'jqm',
			        display: 'modal',
			        mode: 'mixed'
			    });
			});
        </script>
    </body>
</html>
